package com.mspbots.core.ticketai;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.mspbots.core.AbstractBaseController;
import com.mspbots.core.ticketai.model.UserDefaultBoard;
import com.mspbots.core.ticketai.service.UserDefaultBoardService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.concurrent.Callable;


@RestController
@RequiredArgsConstructor
@RequestMapping("user/default-board")
public class UserDefaultBoardController extends AbstractBaseController<UserDefaultBoard, UserDefaultBoardService> {

    @GetMapping(path = "select/byEmail")
    public Callable selectOneByEmail(UserDefaultBoard t) {
        return () -> service.getOne(new QueryWrapper<>(t));
    }
}

